import Relay from "react-relay";

export default class SignOrderMutation extends Relay.Mutation {

    static fragments = {};

    getMutation() {
        return Relay.QL`mutation { signOrder  }`;
    }

    getVariables() {
        return {
            argsInput: {
                orderId: this.props.orderId,
                enId: this.props.enId,
                signedContract: this.props.signedContract,
                signedContractUrl1: this.props.signedContractUrl1,
                signedContractUrl2: this.props.signedContractUrl2,
                signedContractUrl3: this.props.signedContractUrl3,
                signedContractUrl4: this.props.signedContractUrl4,
                signedContractUrl5: this.props.signedContractUrl5,
                isOnlineBalance: this.props.isOnlineBalance,
                enquiryId: this.props.enquiryId
            }
        };
    }

    getFatQuery() {
        return Relay.QL`fragment on signOrderPayload {
            signOrder {
                errorCode
                value
                totalResult
                id
                order{
                    status
                }
               
            }
        }`;
    }

    getConfigs() {
        return [{
            type: 'REQUIRED_CHILDREN',
            children: [Relay.QL`
               fragment on signOrderPayload {
            signOrder {
                    errorCode
                    value
                    totalResult
                    id
                    order{
                            status
                        }
                    }
                }
            `]
        }];
    }

}